package com.sharing.backgroundmodule.mapper;

import com.sharing.domain.Hobby;
import com.sharing.domain.UserHobby;
import com.sharing.domain.dto.UserDto;
import org.apache.ibatis.annotations.Mapper;

import java.util.List;

/**
 * @author MingTian
 * @version 1.0
 * @description TODO
 * @date 2023/4/3 10:42
 */
@Mapper
public interface BackstageUserHobbyMapper {
    Integer selectHobbyNumberByUserId(Integer userId);

    List<Hobby> selectHobbyByUserId(Integer userId);

    List<Integer> selectUserIdsByHobby(List<String> hobbies);

    Integer insertHobby(UserHobby userHobby);

    Integer deleteHobby(UserHobby userHobbies);

    List<Integer> selectHobbyIdsByUserId(Integer userId, Integer level, Integer page, Integer size);

    Integer selectHobbyNumByUserId(Integer userId, Integer level);

    List<UserDto> selectUserDtosByHobbyIds(List<Integer> hobbyIds, Integer page, Integer size);

    Integer selectUserDtosNumByHobbyIds(List<Integer> hobbyIds);

    Integer deleteHobbyByUserIdAndHobbyIds(List<Integer> hobbyIds, Integer userId);

    String selectEarlyDate(Integer userId);

    List<UserHobby> selectUserHobbyByUserId(Integer userId);

    List<UserHobby> selectFirstUserHobbyByUserId(Integer userId, Integer num);

    Integer selectHobbyNumbersByUserId(Integer userId);
}